<?php
require_once 'Db.php';
$server = "";
$schema = "";
$user = "";
$password = "";

$tb = 'summary';
//$where = " where buyer_id in (17897) or seller_id in (17896)";
//$where = " where span=3 and date ='2013-12-01'";// where seller_id=17896 or buyer_id=17897";

$db = new Db($server, $schema, $user, $password);
$db->connect();
$tbList = $db->getTables($tb);
var_dump($tbList);
$cnt = count($tbList);

for ($i = 0; $i < $cnt; $i++) {
	$_cnt = $db->delete($tbList[$i], $where);
	echo $db->_sql; echo "<br>";
	echo $tbList[$i] . ' : '. $_cnt ; echo "<br><br>";
}

$db->close();

?>
